package com.racedepartment.model;

public class Rim extends Model {

	private int rim_sk;
	private String name;
	private boolean is_active;
	private int multi_mode;

	public static final String TABLE_NAME = "RIM";

	public static final String RIM_SK = "RIM_SK";
	// TODO Rename in Database from RIM_NAME to name
	public static final String NAME = "NAME";
	public static final String IS_ACTIVE = "IS_ACTIVE";
	public static final String MULTI_MODE = "MULTI_MODE";
	public static final String[] FIELDS = { RIM_SK, NAME, IS_ACTIVE, MULTI_MODE };
	public static final int[] DATATYPES = { DATATYPE_INT, DATATYPE_TEXT,
			DATATYPE_BOOLEAN, DATATYPE_INT };

	/**
	 * @param rim_sk
	 * @param rim_name
	 * @param is_active
	 * @param multi_mode
	 */
	public Rim(int rim_sk, String name, boolean is_active, int multi_mode) {
		super();
		this.rim_sk = rim_sk;
		this.name = name;
		this.is_active = is_active;
		this.multi_mode = multi_mode;
	}

	public int getRim_sk() {
		return rim_sk;
	}

	public void setRim_sk(int rim_sk) {
		this.rim_sk = rim_sk;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public boolean isIs_active() {
		return is_active;
	}

	public void setIs_active(boolean is_active) {
		this.is_active = is_active;
	}

	public int getMulti_mode() {
		return multi_mode;
	}

	public void setMulti_mode(int multi_mode) {
		this.multi_mode = multi_mode;
	}

	@Override
	public String[] getValues() {
		String[] values = new String[4];
		values[0] = new Integer(getRim_sk()).toString();
		values[1] = getName();
		values[2] = getStringValue(is_active);
		values[3] = new Integer(getMulti_mode()).toString();
		return values;
	}

	@Override
	public String[] getFields() {
		return FIELDS;
	}

	@Override
	public int[] getDataTypes() {
		return DATATYPES;
	}

}
